$(function () {
    var jsdId = $('#jsd_id').val();
    $("#grid_item_fpdr").edatagrid({
        url: $.webPath() + "/cwgl/fpdr/fpdrVoucherItemDataList?jsdId="+jsdId,
        fitColumns: true,
        singleSelect: true,
        checkOnSelect: false,
        selectOnCheck: false,
        rownumbers: true,
        showFooter:true,
        columns: [
            [
                {field: 'zy', title: '摘要', width: 60},
                {field: 'kmmc', title: '科目', width: 40},
                {field: 'fphm', title: '发票号码', width: 20},
                {field: 'jf', title: '借方', width: 30},
                {field: 'df', title: '贷方', width: 30},
                {field: 'fzhsbm_qc', title: '部门', width: 30},
                {field: 'xm', title: '项目', width: 40}
            ]
        ]
    })

    //搜索电子借款单
//    $("#btn_fpdr_add").click(function () {
//        var gldwId = $('#fksh_gldw_id').combotree('getValue');
//        if(gldwId){
//            searcJkdhwindow(grid_jkd_searchWindowOKbtnHandler);
//        }   else {
//            $.messager.alert('提示','请先选择供应商!', "info");
//        }
//
//    });
    //删除电子借款单的按钮触发
//    $("#btn_fpdr_del").click(function () {
//        var jkdRow = $('#jkd_grid').datagrid('getSelected');
//        var jkdIndex = $('#jkd_grid').datagrid('getRowIndex',jkdRow);
//        $('#jkd_grid').edatagrid('deleteRow',jkdIndex);
//    });
});